package com.nbsaas.boot.product.rest.convert;

import com.nbsaas.boot.product.data.entity.ProductSku;
import com.nbsaas.boot.product.api.domain.simple.ProductSkuSimple;

import com.nbsaas.boot.rest.api.Converter;

/**
* 商品SKU-列表对象转换器
*/

public class ProductSkuSimpleConvert implements Converter<ProductSkuSimple, ProductSku> {




@Override
public ProductSkuSimple convert(ProductSku source) {
    ProductSkuSimple result = new ProductSkuSimple();

                result.setImage(source.getImage());
                result.setNote(source.getNote());
                result.setMarketPrice(source.getMarketPrice());
                result.setProductId(source.getProductId());
                result.setSpecificationJson(source.getSpecificationJson());
                result.setCostPrice(source.getCostPrice());
                result.setWeight(source.getWeight());
                result.setSort(source.getSort());
                result.setSpecifications(source.getSpecifications());
                result.setAddDate(source.getAddDate());
                result.setSales(source.getSales());
                result.setSkuName(source.getSkuName());
                result.setVolume(source.getVolume());
                result.setWarningStock(source.getWarningStock());
                result.setPrice(source.getPrice());
                result.setId(source.getId());
                result.setStock(source.getStock());
                result.setSkuCode(source.getSkuCode());
                result.setStatus(source.getStatus());
                result.setLastDate(source.getLastDate());


    return result;
}

}